<div class="row">
<div class="large-10 large-centered column">
	<div class="large-7 columns">
<div id="postid" class="form-comment-wrap large-12 columns">
	<ul class="inline-list">
		<li><a href=""><i class="fa fa-list-ol"></i>&nbsp;&nbsp;Status Update&nbsp;&nbsp;|</a></li>
		<li><a href=""><i class="fa fa-camera"></i>&nbsp;&nbsp;Upload Photo&nbsp;&nbsp;|</a></li>
		<li><a href=""><i class="fa fa-bar-chart"></i>&nbsp;&nbsp;Create Poll</a></li>
	</ul>
	<div class="text-area large-12 columns">
		<textarea id="info" required placeholder="What's in your mind?"></textarea>
	</div>
	<div id="out">
	</div>
	

	<div class="large-12 columns">
		<a id="btnPost" class="postbutton right button">Post</a>
	</div>
</div>		
	</div>
	<div class="large-5 columns">
		
	</div>
</div>
</div>
<img src="<?php echo BASE_URI; ?>img/new.jpg">

<style type="text/css">
body{
	background: white;
	background-size: cover;
}
</style>




<script type="text/javascript">
	$('#info').on("input",function(){	
		var text = $(this).val();
		var reg = /(http|https|ftp|ftps)\:\/\/[a-zA-Z0-9\-\.]+\.[a-zA-Z]{2,3}(\/\S*)?/;
		if(reg.test(text)){
			$.ajax({
				url: URL + 'feeds/convert',
				data: {text:text},
				type: 'get',
				dataType: 'json',
				success: function(data){
					if(data.status == true)
					{	
						$('#out').html(data.html);	
					}
				}
			});
		}
	});  

	
$('#btnPost').click(function(){
	var comments = $('#info').val();
	var content = '';
		$.ajax({
			url: URL + 'feeds/insert',
			type: 'post',
			data: {content:Linkify(comments),html:$('#out').html()},
			success: function(result){
				console.log(result);
			}
		});
});

</script>